package org.gw.ylc.base.service;

import org.gw.ylc.base.model.GradeMajor;
import org.gw.ylc.base.repositories.GradeMajorRepository;
import org.gw.ylc.base.util.PermissionUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class GradeMajorService {
	@Autowired
	private GradeMajorRepository gradeMajorRepository;

	public Iterable<GradeMajor> findAll() {
		return gradeMajorRepository.findByDepartment(PermissionUtil.getFilteredDepartmentId(null));
	}
}
